/*
 * @Description: 适配规则
 * @Author: gaoyunpeng
 * @Date: 2022-01-21 16:16:30
 * @LastEditors: gaoyunpeng
 */
const baseSize = 16
function setRem() {
  const scale = document.documentElement.clientWidth / 1920
  document.documentElement.style.fontSize = baseSize * Math.min(scale, 2) + 'px'
}
// 初始化
setRem()
// 改变窗口大小时重新设置 rem
window.onresize = function () {
  setRem()
}
